<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core">

<h:head>
	<title><h:outputText value="#{index.constant.siteName}" /></title>
</h:head>

<h:body>
	<h:form>
		<h:dataTable value="#{linkBean.allLinks}" var="link">
			<h:column>
				<f:facet name="header">
					<h:outputText value="Quantity" />
				</f:facet>
				<h:outputText value="#{link.id }"></h:outputText>
			</h:column>

			<h:column>
				<f:facet name="header">
					<h:outputText value="siteName" />
				</f:facet>
				<h:commandLink action="#{linkBean.edit}">
					<h:outputText value="#{link.siteName}"></h:outputText>
				</h:commandLink>
			</h:column>
			<h:column>
				<f:facet name="header">
					<h:outputText value="状态" />
				</f:facet>
				<h:selectOneMenu>
					<f:selectItem itemValue="2" itemLabel="sdf" />
					<f:selectItem itemValue="5" itemLabel="sdsf" />
					<f:selectItem itemValue="7" itemLabel="sdfsd" />
				</h:selectOneMenu>
			</h:column>

			<h:column>
				<f:facet name="header">
					<h:outputText value="操作"></h:outputText>
				</f:facet>
				<h:outputLink value="/admin/link/input/#{link.id}">
					<h:outputText value="编辑"></h:outputText>
				</h:outputLink>
				<h:commandLink value="删除" actionListener="#{linkBean.del}">
				</h:commandLink>
			</h:column>
		</h:dataTable>
		<h:commandLink action="#{linkBean.add}" value="addNew"></h:commandLink>
	</h:form>
</h:body>
</html>